\(\int \frac {a+b \log (c (e+f x))}{(d e+d f x) (h+i x)} \, dx\) [180]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [B] (verified)
   Fricas [F]
   Sympy [F]
   Maxima [F]
   Giac [F]
   Mupad [F(-1)]

Optimal result

Integrand size = 30, antiderivative size = 87 \[ \int \frac {a+b \log (c (e+f x))}{(d e+d f x) (h+i x)} \, dx=-\frac {(a+b \log (c (e+f x))) \log \left (1+\frac {f h-e i}{i (e+f x)}\right )}{d (f h-e i)}+\frac {b \operatorname {PolyLog}\left (2,-\frac {f h-e i}{i (e+f x)}\right )}{d (f h-e i)} \]

[Out]

-(a+b*ln(c*(f*x+e)))*ln(1+(-e*i+f*h)/i/(f*x+e))/d/(-e*i+f*h)+b*polylog(2,(e*i-f*h)/i/(f*x+e))/d/(-e*i+f*h)

Rubi [A] (verified)

Time = 0.13 (sec) , antiderivative size = 87, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.133, Rules used = {2458, 12, 2379, 2438} \[ \int \frac {a+b \log (c (e+f x))}{(d e+d f x) (h+i x)} \, dx=\frac {b \operatorname {PolyLog}\left (2,-\frac {f h-e i}{i (e+f x)}\right )}{d (f h-e i)}-\frac {\log \left (\frac {f h-e i}{i (e+f x)}+1\right ) (a+b \log (c (e+f x)))}{d (f h-e i)} \]

[In]

Int[(a + b*Log[c*(e + f*x)])/((d*e + d*f*x)*(h + i*x)),x]

[Out]

-(((a + b*Log[c*(e + f*x)])*Log[1 + (f*h - e*i)/(i*(e + f*x))])/(d*(f*h - e*i))) + (b*PolyLog[2, -((f*h - e*i)
/(i*(e + f*x)))])/(d*(f*h - e*i))

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 2379

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)/((x_)*((d_) + (e_.)*(x_)^(r_.))), x_Symbol] :> Simp[(-Log[1 +
d/(e*x^r)])*((a + b*Log[c*x^n])^p/(d*r)), x] + Dist[b*n*(p/(d*r)), Int[Log[1 + d/(e*x^r)]*((a + b*Log[c*x^n])^
(p - 1)/x), x], x] /; FreeQ[{a, b, c, d, e, n, r}, x] && IGtQ[p, 0]

Rule 2438

Int[Log[(c_.)*((d_) + (e_.)*(x_)^(n_.))]/(x_), x_Symbol] :> Simp[-PolyLog[2, (-c)*e*x^n]/n, x] /; FreeQ[{c, d,
 e, n}, x] && EqQ[c*d, 1]

Rule 2458

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.)*((f_.) + (g_.)*(x_))^(q_.)*((h_.) + (i_.)*(x_))
^(r_.), x_Symbol] :> Dist[1/e, Subst[Int[(g*(x/e))^q*((e*h - d*i)/e + i*(x/e))^r*(a + b*Log[c*x^n])^p, x], x,
d + e*x], x] /; FreeQ[{a, b, c, d, e, f, g, h, i, n, p, q, r}, x] && EqQ[e*f - d*g, 0] && (IGtQ[p, 0] || IGtQ[
r, 0]) && IntegerQ[2*r]

Rubi steps \begin{align*} \text {integral}& = \frac {\text {Subst}\left (\int \frac {a+b \log (c x)}{d x \left (\frac {f h-e i}{f}+\frac {i x}{f}\right )} \, dx,x,e+f x\right )}{f} \\ & = \frac {\text {Subst}\left (\int \frac {a+b \log (c x)}{x \left (\frac {f h-e i}{f}+\frac {i x}{f}\right )} \, dx,x,e+f x\right )}{d f} \\ & = -\frac {(a+b \log (c (e+f x))) \log \left (1+\frac {f h-e i}{i (e+f x)}\right )}{d (f h-e i)}+\frac {b \text {Subst}\left (\int \frac {\log \left (1+\frac {f h-e i}{i x}\right )}{x} \, dx,x,e+f x\right )}{d (f h-e i)} \\ & = -\frac {(a+b \log (c (e+f x))) \log \left (1+\frac {f h-e i}{i (e+f x)}\right )}{d (f h-e i)}+\frac {b \text {Li}_2\left (-\frac {f h-e i}{i (e+f x)}\right )}{d (f h-e i)} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.05 (sec) , antiderivative size = 91, normalized size of antiderivative = 1.05 \[ \int \frac {a+b \log (c (e+f x))}{(d e+d f x) (h+i x)} \, dx=\frac {(a+b \log (c (e+f x))) \left (a+b \log (c (e+f x))-2 b \log \left (\frac {f (h+i x)}{f h-e i}\right )\right )-2 b^2 \operatorname {PolyLog}\left (2,\frac {i (e+f x)}{-f h+e i}\right )}{2 b d (f h-e i)} \]

[In]

Integrate[(a + b*Log[c*(e + f*x)])/((d*e + d*f*x)*(h + i*x)),x]

[Out]

((a + b*Log[c*(e + f*x)])*(a + b*Log[c*(e + f*x)] - 2*b*Log[(f*(h + i*x))/(f*h - e*i)]) - 2*b^2*PolyLog[2, (i*
(e + f*x))/(-(f*h) + e*i)])/(2*b*d*(f*h - e*i))

Maple [B] (verified)

Leaf count of result is larger than twice the leaf count of optimal. \(176\) vs. \(2(86)=172\).

Time = 0.97 (sec) , antiderivative size = 177, normalized size of antiderivative = 2.03

method result size
parts \(\frac {a \left (\frac {\ln \left (i x +h \right )}{e i -f h}-\frac {\ln \left (f x +e \right )}{e i -f h}\right )}{d}-\frac {b \ln \left (c f x +c e \right )^{2}}{2 d \left (e i -f h \right )}+\frac {b \operatorname {dilog}\left (\frac {-c e i +h c f +i \left (c f x +c e \right )}{-c e i +h c f}\right )}{d \left (e i -f h \right )}+\frac {b \ln \left (c f x +c e \right ) \ln \left (\frac {-c e i +h c f +i \left (c f x +c e \right )}{-c e i +h c f}\right )}{d \left (e i -f h \right )}\) \(177\)
risch \(\frac {a \ln \left (i x +h \right )}{d \left (e i -f h \right )}-\frac {a \ln \left (f x +e \right )}{d \left (e i -f h \right )}-\frac {b \ln \left (c f x +c e \right )^{2}}{2 d \left (e i -f h \right )}+\frac {b \operatorname {dilog}\left (\frac {-c e i +h c f +i \left (c f x +c e \right )}{-c e i +h c f}\right )}{d \left (e i -f h \right )}+\frac {b \ln \left (c f x +c e \right ) \ln \left (\frac {-c e i +h c f +i \left (c f x +c e \right )}{-c e i +h c f}\right )}{d \left (e i -f h \right )}\) \(179\)
derivativedivides \(\frac {-\frac {c f a \ln \left (c f x +c e \right )}{d \left (e i -f h \right )}+\frac {c f a \ln \left (c e i -h c f -i \left (c f x +c e \right )\right )}{d \left (e i -f h \right )}-\frac {c^{2} f b \left (\frac {\ln \left (c f x +c e \right )^{2}}{2 c \left (e i -f h \right )}-\frac {i \left (\frac {\operatorname {dilog}\left (\frac {-c e i +h c f +i \left (c f x +c e \right )}{-c e i +h c f}\right )}{i}+\frac {\ln \left (c f x +c e \right ) \ln \left (\frac {-c e i +h c f +i \left (c f x +c e \right )}{-c e i +h c f}\right )}{i}\right )}{c \left (e i -f h \right )}\right )}{d}}{c f}\) \(214\)
default \(\frac {-\frac {c f a \ln \left (c f x +c e \right )}{d \left (e i -f h \right )}+\frac {c f a \ln \left (c e i -h c f -i \left (c f x +c e \right )\right )}{d \left (e i -f h \right )}-\frac {c^{2} f b \left (\frac {\ln \left (c f x +c e \right )^{2}}{2 c \left (e i -f h \right )}-\frac {i \left (\frac {\operatorname {dilog}\left (\frac {-c e i +h c f +i \left (c f x +c e \right )}{-c e i +h c f}\right )}{i}+\frac {\ln \left (c f x +c e \right ) \ln \left (\frac {-c e i +h c f +i \left (c f x +c e \right )}{-c e i +h c f}\right )}{i}\right )}{c \left (e i -f h \right )}\right )}{d}}{c f}\) \(214\)

[In]

int((a+b*ln(c*(f*x+e)))/(d*f*x+d*e)/(i*x+h),x,method=_RETURNVERBOSE)

[Out]

a/d*(1/(e*i-f*h)*ln(i*x+h)-1/(e*i-f*h)*ln(f*x+e))-1/2*b/d/(e*i-f*h)*ln(c*f*x+c*e)^2+b/d/(e*i-f*h)*dilog((-c*e*
i+h*c*f+i*(c*f*x+c*e))/(-c*e*i+c*f*h))+b/d/(e*i-f*h)*ln(c*f*x+c*e)*ln((-c*e*i+h*c*f+i*(c*f*x+c*e))/(-c*e*i+c*f
*h))

Fricas [F]

\[ \int \frac {a+b \log (c (e+f x))}{(d e+d f x) (h+i x)} \, dx=\int { \frac {b \log \left ({\left (f x + e\right )} c\right ) + a}{{\left (d f x + d e\right )} {\left (i x + h\right )}} \,d x } \]

[In]

integrate((a+b*log(c*(f*x+e)))/(d*f*x+d*e)/(i*x+h),x, algorithm="fricas")

[Out]

integral((b*log(c*f*x + c*e) + a)/(d*f*i*x^2 + d*e*h + (d*f*h + d*e*i)*x), x)

Sympy [F]

\[ \int \frac {a+b \log (c (e+f x))}{(d e+d f x) (h+i x)} \, dx=\frac {\int \frac {a}{e h + e i x + f h x + f i x^{2}}\, dx + \int \frac {b \log {\left (c e + c f x \right )}}{e h + e i x + f h x + f i x^{2}}\, dx}{d} \]

[In]

integrate((a+b*ln(c*(f*x+e)))/(d*f*x+d*e)/(i*x+h),x)

[Out]

(Integral(a/(e*h + e*i*x + f*h*x + f*i*x**2), x) + Integral(b*log(c*e + c*f*x)/(e*h + e*i*x + f*h*x + f*i*x**2
), x))/d

Maxima [F]

\[ \int \frac {a+b \log (c (e+f x))}{(d e+d f x) (h+i x)} \, dx=\int { \frac {b \log \left ({\left (f x + e\right )} c\right ) + a}{{\left (d f x + d e\right )} {\left (i x + h\right )}} \,d x } \]

[In]

integrate((a+b*log(c*(f*x+e)))/(d*f*x+d*e)/(i*x+h),x, algorithm="maxima")

[Out]

a*(log(f*x + e)/(d*f*h - d*e*i) - log(i*x + h)/(d*f*h - d*e*i)) + b*integrate((log(f*x + e) + log(c))/(d*f*i*x
^2 + d*e*h + (f*h + e*i)*d*x), x)

Giac [F]

\[ \int \frac {a+b \log (c (e+f x))}{(d e+d f x) (h+i x)} \, dx=\int { \frac {b \log \left ({\left (f x + e\right )} c\right ) + a}{{\left (d f x + d e\right )} {\left (i x + h\right )}} \,d x } \]

[In]

integrate((a+b*log(c*(f*x+e)))/(d*f*x+d*e)/(i*x+h),x, algorithm="giac")

[Out]

integrate((b*log((f*x + e)*c) + a)/((d*f*x + d*e)*(i*x + h)), x)

Mupad [F(-1)]

Timed out. \[ \int \frac {a+b \log (c (e+f x))}{(d e+d f x) (h+i x)} \, dx=\int \frac {a+b\,\ln \left (c\,\left (e+f\,x\right )\right )}{\left (h+i\,x\right )\,\left (d\,e+d\,f\,x\right )} \,d x \]

[In]

int((a + b*log(c*(e + f*x)))/((h + i*x)*(d*e + d*f*x)),x)

[Out]

int((a + b*log(c*(e + f*x)))/((h + i*x)*(d*e + d*f*x)), x)